package com.solutionsfit.timesheet

import groovy.util.GroovyTestCase
import com.solutionsfit.timesheet.PayPeriod
import com.solutionsfit.timesheet.PayPeriodType 

class PayPeriodTest extends GroovyTestCase {
	
	void testEquals() {

		PayPeriod payPeriod1 = new PayPeriod(3,2008, PayPeriodType.FIRST)
		PayPeriod payPeriod2 = new PayPeriod(3,2008, PayPeriodType.FIRST)
		
		assertTrue payPeriod1 == payPeriod2

	}
	
	void testNotEquals() {

		PayPeriod payPeriod1 = new PayPeriod(3,2008, PayPeriodType.FIRST)
		PayPeriod payPeriod2 = new PayPeriod(3,2008, PayPeriodType.SECOND)
		
		assertFalse payPeriod1 == payPeriod2
		
		assertFalse payPeriod1 == null
		
	}
	

}